import Vue from 'vue'
import Router from 'vue-router'
import Home from '@/components/home/home' // 项目根入口
import Index from '@/components/index' // 首页
import Apply from '@/components/index/apply' // 申请
import List from '@/components/index/list' // 列表
import Inquier from '@/components/index/inquier' // 列表
import Notice from '@/components/index/notice' // 列表
import oerror from '@/components/index/error' // 错误页
Vue.use(Router)
const router = new Router({
  mode: 'history',
  // base: '/projectweb/',
  linkActiveClass: 'active',
  routes: [
    {
      path: '/', // 根目录
      name: 'home',
      component: Home,
      redirect: '/index',
      children: [
        {
          path: 'index', // 首页
          name: 'index',
          component: Index
        },
        {
          path: 'list', // 列表
          name: 'list',
          component: List
        },
        {
          path: 'apply', // 申请
          name: 'apply',
          component: Apply
        },
        {
          path: 'inquier', // 审核
          name: 'inquier',
          component: Inquier
        },
        {
          path: 'notice', // 审核
          name: 'notice',
          component: Notice
        },
        {
          path: 'error', // 审核
          name: 'error',
          component: oerror
        }
      ]
    }
  ]
})
export default router
